
abstract class DataView{
  data:string;
  abstract convertData():void;
  abstract isNeedConvert():boolean;
  display():void{
    console.log(`显示数据:${this.data}`);
  };
  process():void{
    console.log(`原始数据：${this.data}`);
    if(this.isNeedConvert()){
      console.log(`需要转换`);
      this.convertData();
    }
    this.display();
  }
}

export {DataView};